// compile:
// run:
#include <iostream>
#include <shared_mutex>
using namespace std;

struct ThreadSafe {
  mutable std::shared_timed_mutex mutex_;
  int value_;
  ThreadSafe() { value_ = 0; }
  int get() const {
    std::shared_lock<std::shared_timed_mutex> loc(mutex_);
    return value_;
  }
  void increase() {
    std::unique_lock<std::shared_timed_mutex> lock(mutex_);
    value_ += 1;
  }
};

void Test1() {}
void Test2() {}
int main() {
  Test1();
  Test2();
  return 0;
}
